{extend name='admin@main'}
{block name="content"}
<div class="think-box-shadow">
    {include file='order/index_search'}
    <div class="layui_table_width_scroll">
     <table class="layui-table margin-top-10" lay-skin="line">
        {notempty name='list'}
        <thead>
        <tr>
            <th class="text-left nowrap">订单ID</th>
            <th class='text-left nowrap'>支付方式</th>
            <th class='text-left nowrap'>用户ID</th>
            <th class='text-left nowrap'>渠道</th>
            <th class='text-left nowrap'>配置金额</th>
            <th class='text-left nowrap'>实付金额</th>
            <th class='text-left nowrap'>第三方订单号</th>
            <th class='text-left nowrap'>商品ID</th>
            <th class='text-left nowrap'>商品名</th>
            <th class='text-left nowrap'>状态</th>
            <th class='text-left nowrap'>发起订单时间</th>
            <th class='text-left nowrap'>完成订单时间</th>
            <th class='text-left nowrap'>服务器来源</th>
        </tr>
        </thead>
        {/notempty}
        <tbody>
        {foreach $list as $key=>$vo}
        <tr>
            <td class='text-left nowrap'>
                <span class="color-blue">{$vo.id|default=''}</span>
                {eq name='vo.status' value='0'}<span class="layui-badge layui-bg-orange margin-left-5">待支付</span>{/eq}
                {eq name='vo.status' value='1'}<span class="layui-badge layui-bg-blue margin-left-5">已支付</span>{/eq}
            </td>
            <td class='text-left nowrap'>{$vo.trade_name}</td>
            <td class='text-left nowrap'>
                <span class="color-red">{$vo.userid|default=''}</span>
            </td>
            <td class='text-left nowrap'>
                {eq name='$vo.channel_name' value='0' }
                    官方-0-渠道
                    {else}
                    {$vo.channel_name}
                {/eq}
            </td>
            <td class='text-left nowrap'>{$vo.amount}</td>
            <td class='text-left nowrap'>{$vo.amount}￥</td>
            <td class='text-left nowrap'>{$vo.transactionID |default='--'}</td>
            <td class='text-left nowrap'>{$vo.goods_id}</td>
            <td class='text-left nowrap'>{$vo.goods_name}</td>
            <td class='text-left nowrap'>
                {if $vo.status eq 0} 订单未完成
                    {elseif $vo.status eq 1} 订单成功
                {/if}
            </td>
            <td class='text-left nowrap'>{$vo.createdat}</td>
            <td class='text-left nowrap'>{$vo.paydate}</td>
            <td class='text-left nowrap'>{$vo.server_name}</td>
        </tr>
        {/foreach}
        </tbody>
    </table>
    </div>
    {$pages | Raw}
    {empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
</div>
{/block}
